package com.haoshuang.zhouzhoubang.ui.adapter

import com.haoshuang.zhouzhoubang.databinding.ItemFocusDateBinding
import com.haoshuang.zhouzhoubang.model.bean.FocusDateBean
import com.mufeng.libs.base.BaseBindingHolder
import com.mufeng.libs.base.BaseBindingQuickAdapter
import com.mufeng.libs.utils.view.visibleOrGone

/**
 *
 */
class FocusDateAdapter(data: MutableList<FocusDateBean>) :
    BaseBindingQuickAdapter<FocusDateBean, ItemFocusDateBinding>(data) {

    override fun onBindViewHolder(holder: BaseBindingHolder, position: Int, item: FocusDateBean?) {
        if (item == null) return
        holder.getViewBinding<ItemFocusDateBinding>().apply {
            tvTime.text = item.date
            ivTao2.visibleOrGone(item.list?.is_person_order == 1)
            ivTao1.visibleOrGone(item.list?.is_team_order == 1)
            ivTao.visibleOrGone(item.list?.is_taocan_order == 1)
        }
    }
}
